<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,initial-scale=1.0,user-scalable=no" />
        <meta name="apple-mobile-web-app-capable" content="yes" />
        <!-- intoHead Start -->
        {include file="common/intohead" /}
        <!-- /intoHead End -->
    </head>
	<body class="mainbody">
		<!--导航栏-->
		{include file="common/position" /}
		<!--/导航栏-->

		<style>
			.ltable tr:hover {
			    background: #fff;
			}
		</style>

		<div class="line10"></div>

		<div id="floatHead" class="toolbar-wrap" style="height: 52px;">
			<div class="toolbar">
				<div class="box-wrap">
					<a class="menu-btn"></a>
					<div class="l-list">
						<ul class="icon-list">
							<li><a class="add" href="{:url('Access/addRole')}"><i></i><span>新增角色</span></a></li>
							<li><a class="all" href="javascript:;"><i></i><span>全选</span></a></li>
							<li><a data-ids="" id="btnDelete" class="isAllowed" data-url="{:url('Access/delRole')}"><i></i>批量删除</a></li>
						</ul>
					</div>
					<div class="r-list">
						<form action="" method="post">
                            <input name="keyword" type="text" placeholder="用户组ID/用户组" id="txtKeywords" class="keyword">
                            <button id="lbtnSearch" class="btn-search" type="submit">查询</button>
                        </form>
					</div>
				</div>
			</div>
		</div>

		<div class="table-container">
			<table width="100%" border="0" cellspacing="0" cellpadding="0" class="ltable">
				<thead>
					<tr class="odd_bg">
						<th>选择</th>
						<th>用户组ID</th>
						<th>用户组</th>
						<th>用户组描述</th>
						<th>授权</th>
						<th>状态</th>
						<th>操作</th>
					</tr>
				</thead>
				<tbody>
					{volist name="authgroup" id="vo" key="k"}
						<tr>
							<td><span class="td check-option r1 checkall" style="width: 4%;"><input type="checkbox" name="id[]"  value="{$vo.id}"></span></td>
							<td>{$vo.id}</td>
	                    	<td>{$vo.title}</td>
	                    	<td>{$vo.description|default='无'}</td>
							<td>
								[ <a href="{:url('Access/authRole',array('id'=>encode($vo['id'])))}" class="btn-xs btn-link ng-scope ng-isolate-scope">角色授权</a> ]
							</td>
							<td>{$vo['status']?'正常':'禁用'}</td>
							<td>
								[ <a href="{:url('Access/disabledRole',array('id'=>encode($vo['id']),'status'=>encode($vo['status'])))}" class="btn-xs btn-link ng-scope ng-isolate-scope delete" data-url="/index.php?s=/Access/disabledRole.html">{$vo['status']?'禁用':'正常'}</a> ]
								<span class="text-explode">|</span>
								[ <a href="javascript:;" data-url="{:url('Access/delRole')}" data-ids="{$vo.id}" class="check_a btn-link button isConfirm" style="background: #fff;border: none;cursor: pointer;">删除</a> ]
					        </td>
						</tr>
					{/volist}
				</tbody>
			</table>

		</div>
		<div class="line20"></div>
		<!--数据分页-->
		<div class="page-bootstrap">{$authgroup->render()}</div>
	</body>
</html>